// https://www.npmjs.com/package/mitt
import mitt from 'mitt'
import type {Emitter} from 'mitt'
import {ipcRenderer} from "electron";

// 类型
export const emitter: Emitter<MittType> = mitt<MittType>()

// 打开用户文件夹选择
export const openSelectDirectory = () => {
    ipcRenderer.send('select-directory')
}
